package com.itzdm.client.fallback;

import com.itzdm.client.client.UserClient;
import com.itzdm.client.domain.UserSearchDto;
import org.springframework.cloud.openfeign.FallbackFactory;

import java.util.List;

/**
 * @作者：张德明
 * @时间：2025/4/6 12:53
 */
public class UserFallback implements FallbackFactory<UserClient> {
    @Override
    public UserClient create(Throwable cause) {
        return new UserClient() {

            @Override
            public UserSearchDto getUserInfo(String keyword) {
                return null;
            }

            @Override
            public UserSearchDto getUserInfoById(Long userId) {
                return null;
            }

            @Override
            public List<UserSearchDto> getUserInfoByIds(List<Long> userIds) {
                return List.of();
            }
        };
    }
}
